home *** CD-ROM | disk | FTP | other *** search
/ PsL Monthly 1993 December / PSL Monthly Shareware CD-ROM (December 1993).iso / prgmming / dos / try_qb / edpat.bas (.txt) < prev    next >
QuickBASIC Tokenized Source  |  1989-12-04  |  5KB  |  81 lines

  1. DrawPattern
  2. EditPattern
  3. Initialize
  4. ShowPattern
  5. Pattern
  6. PatternSize
  7. ByteNum
  8. BitNum
  9. State
  10. RefTime
  11. Check
  12. CurrentByte
  13. CurrentColor
  14. PatternByte
  15. DrawPattern
  16. = DRAWPATTERN 
  17.  Draws a patterned rectangle on the right side of screen
  18.  Set view to rectangle
  19.  Use PAINT to fill itr
  20.  Set view to full screen
  21. EditPattern
  22. = EDITPATTERN 
  23.  Edits a tile-byte pattern
  24.  Starting position.=
  25.  CHR$(0) is the first byte of the=
  26.  two-byte string returned when a
  27.  direction key such as UP or DOWN is
  28.  pressed.n
  29.  Calculate starting location on screen of this bit:=
  30.  Wait for a key press (and flash cursor each 3/10 second):
  31.  Check timer and switch cursor state if 3/10 second:
  32.  Turn the  border of bit on and off:
  33.  Check for key press.
  34.  Loop until a key is pressed.0
  35.  Erase cursor:
  36.  Respond to key press.
  37.  ESC key pressed:r
  38.  exit this subprogramr
  39.  SPACEBAR pressed:
  40.  reset state of bits
  41.  Invert bit in pattern string:
  42.  Redraw bit on screen:
  43.  ENTER key pressed:
  44.  draw pattern in box on right.
  45.  LEFT key: move cursor leftd
  46.  RIGHT key: move cursor right
  47.  UP key: move cursor up 
  48.  DOWN key: move cursor downh
  49.  User pressed a key other than ESC, SPACEBAR,
  50.  ENTER, UP, DOWN, LEFT, or RIGHT, so don't
  51.  do anything.O
  52. Initialize
  53. = INITIALIZE 
  54.  Sets up starting pattern and screen
  55.  ESC character is ASCII 27.=
  56.  Set up an array holding bits in positions 0 to 7:
  57.  Input the pattern size (in number of bytes):t
  58. Enter pattern size (1-16 rows):"
  59.  Set initial pattern to all bits set: 
  60.  640 x 200 monochrome graphics mode.
  61.  Draw dividing lines:n
  62.  Print titles:
  63. Pattern Bytes"
  64. Pattern View
  65.  Draw editing screen for pattern:p
  66.  Print label on left of each line:
  67.  Draw "bit" boxes:
  68.  Draw  "Pattern View" box.
  69. DIRECTION keys........Move cursor"
  70. SPACEBAR............Changes point"
  71. ENTER............Displays pattern"
  72. ESC.........................Quits"
  73. ShowPattern
  74. = SHOWPATTERN 
  75.  Prints the CHR$ values used by PAINT to make pattern=
  76.  Return screen to 80-column text mode:
  77. The following characters make up your pattern:
  78.  Print out the value for each pattern byte::
  79. CHR$("
  80. New pattern? "
  81.